﻿@model LeadMaster.Models.ReferralCats

@{
    ViewBag.Title = "Edit";
}

<h2>Edit Referral Category</h2>
<div class="spacer"></div>
@using (Html.BeginForm("Edit", "ReferralCats", FormMethod.Post, new { @class = "formEditReferralCategory" }))
{
    @Html.ValidationSummary(true)
    <fieldset style="border-style: none; width: 500px;">
    @Html.HiddenFor(m => m.ReferralCatsID)
        <div>
            <label>Description</label>
        </div>
        <div>
            <input type="text" name="Description" id="Description" value="@(Model.Description)" style="font-family: Consolas; font-size: 14px; width: 300px" />
        </div>
        <div class="spacer"></div>
        <div>
            <label>Parent Category</label>
        </div>
        <div>
            @Html.DropDownListFor(model => model.ParentReferralCatsID, new SelectList(ViewBag.Categories, "Value", "Text", Model.ParentReferralCatsID),"Please select a Parent Category", new { @class = "chosen", style = "width: 300px;" })
        </div>
        <div class="spacer"></div>
        <p>
        <input type="submit" value="Save"
        </p>
    </fieldset>
}
<div class="spacer"></div>

<a href="@Url.Action("Index")">Back To List</a>

<script type="text/javascript">
    $(document).ready(function () {

        $(".chosen").chosen();

    });
</script>